home *** CD-ROM | disk | FTP | other *** search
/ Sprite 1984 - 1993 / Sprite 1984 - 1993.iso / lib / tcl / demos / hello < prev    next >
Text File  |  1992-04-29  |  423b  |  13 lines

  1. #!/usr/local/wish -f
  2. # Simple Tk script to create a button that prints "Hello, world".
  3. # Click on the button to terminate the program.
  4. # The first line below creates the button, and the second line
  5. # arranges for packer to manage the button's geometry, centering
  6. # it in the application's main window.
  7.  
  8. button .hello -text "Hello, world" -command {
  9.     puts stdout "Hello, world"; destroy .
  10. }
  11. pack append . .hello {top}
  12.